<template>
  <div class="quick-input">
    <span>快捷输入：</span>
    <div class="input-list">
      <span v-for="(item,index) in options" :key="index" @click="itemClick(item)">{{item}}</span>
    </div>
  </div>
</template>

<script lang="ts">
import {Component, Vue} from 'vue-property-decorator';
import {categoryData} from '@/api/investCode';
@Component
export default class QuickInput extends Vue {
  options = ['调查对象范围有误','填报信息内容有误','空间位置出错','调查对象填报类型错误','填报信息不规范']
  itemClick(item){
    this.$emit('change',item)
  }
  mounted(){
    categoryData({'category':"审核标错"}).then((response: any) => {
      if (response.data) {
          this.options = [];
          Object.keys(response.data).forEach(k => {
            this.options.push(response.data[k])
          });
      }
    }).catch((e) => {
      console.error(e);
    });
  }
}
</script>
<style lang="scss" scoped>
.quick-input{
  display: flex;
  gap: 10px;
  font-size: 14px;
  margin-bottom: 10px;
  .input-list{
    flex: 1;
    span{
      color: #333333;
      text-decoration: underline;
      margin-right: 10px;
      cursor: pointer;
    }
  }
}
</style>
